
using SinBiota.Model.Business.AuthenticationServices;
using SinBiota.Model.Business.AuthenticationServices.Implementation;
using SinBiota.Model.Business.AuthenticationServices.Interfaces;
using SinBiota.Model.Business.CoordinatesServices.Implementation;
using SinBiota.Model.Business.CoordinatesServices.Interfaces;
using SinBiota.Model.Business.DataAccess;
using SinBiota.Model.Business.MapServices.Implementation;
using SinBiota.Model.Business.MapServices.Interfaces;
using SinBiota.Model.Business.OccurrenceServices.Implementation;
using SinBiota.Model.Business.OccurrenceServices.Interfaces;
using SinBiota.Model.Business.PersistenceServices.Implementation;
using SinBiota.Model.Business.PersistenceServices.Interfaces;
using SinBiota.Model.Business.ProjectServices.Implementation;
using SinBiota.Model.Business.ProjectServices.Interfaces;
using SinBiota.Model.Business.StatisticsServices.Implementation;
using SinBiota.Model.Business.StatisticsServices.Interfaces;
using StructureMap.Configuration.DSL;

namespace Sinbiota.Web.Initialization.StructureMap
{
    public class BusinessRegistry : Registry
    {
        public BusinessRegistry()
        {
            //Authentication
            For<IAuthentication>().Use<SinBiota.Model.Business.AuthenticationServices.Implementation.Authentication>();
            For<IPermissionServices>().Use<PermissionServices>();

            //Statistics 
            For<ISinbiotaStatistics>().Use<SinbiotaStatistics>();
            For<IOccurrenceStatistics>().Use<OccurrenceStatistics>();
            For<ISpeciesStatistics>().Use<SpeciesStatistics>();

            // MapServices:
            For<ITileLayerServices>().Use<TileLayerServices>();
            For<ISpatialServices>().Use<SpatialServices>();
            For<IMapDatabaseServices>().Use<MapDatabaseServices>();
            For<IDrawingServices>().Use<DrawingServices>();
            For<IHeatMapServices>().Use<HeatMapServices>();
            For<IAutoCompleteServices>().Use<AutoCompleteServices>();
            For<ICoordinatesConversion>().Use<CoordinatesConversion>();

            // Persistence Services:
            For<IConservationUnitPersistenceServices>().Use<ConservationUnitPersistenceServices>();
            For<IDrainageBasinPersistenceServices>().Use<DrainageBasinPersistenceServices>();
            For<IEcosystemPersistenceServices>().Use<EcosystemPersistenceServices>();
            For<IHabitatPersistenceServices>().Use<HabitatPersistenceServices>();
            For<IInstitutionPersistenceServices>().Use<InstitutionPersistenceServices>();
            For<IKeywordPersistenceServices>().Use<KeywordPersistenceServices>();
            For<IMethodPersistenceServices>().Use<MethodPersistenceServices>();
            For<IMicroHabitatPersistenceServices>().Use<MicroHabitatPersistenceServices>();
            For<IMunicipalityPersistenceServices>().Use<MunicipalityPersistenceServices>();
            For<IProjectPersistenceServices>().Use<ProjectPersistenceServices>();
            For<IUserPersistenceServices>().Use<UserPersistenceServices>();
            For<IProjectPersistenceServices>().Use<ProjectPersistenceServices>();
            For<ILogQueryingServices>().Use<LogQueryingServices>();
            For<IDepositaryUnitPersistenceServices>().Use<DepositaryUnitPersistenceServices>();
            For<IPublicationPersistenceServices>().Use<PublicationPersistenceServices>();
            For<IOccurrencePersistenceServices>().Use<OccurrencePersistenceServices>();
            For<ITaxonPersistenceServices>().Use<TaxonPersistenceServices>();
            For<ILocationPersistenceServices>().Use<LocationPersistenceServices>();

            //ProjectServices:
            For<IProjectManagement>().Use<ProjectManagement>();

            // Occurrence:
            For<ITaxonomyServices>().Use<TaxonomyServices>();
        }
    }
}